package jeju.daum.service;

import java.util.List;
import jeju.daum.model.Comment;
import jeju.daum.repository.CommentDao;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class CommentServiceImpl implements CommentService{

	@Autowired CommentDao commentDao;
	
	@Override
	public List<Comment> getCommentList() {
		return commentDao.getCommentList();
	}

	@Override
	public void saveComment(Comment comment) {
		commentDao.saveComment(comment);
	}

	@Override
	public void deleteComment(int seq_num) {
		commentDao.deleteComment(seq_num);
	}

	@Override
	public Comment getComment(int seq_num) {
		return commentDao.getComment(seq_num);
	}

	@Override
	public int getMaxSeqNum() {
		return commentDao.getMaxSeqNum();
	}

	@Override
	public void incrementRecommend(int seq_num) {
		commentDao.incrementRecommend(seq_num);
	}

	@Override
	public void incrementOppose(int seq_num) {
		commentDao.incrementOppose(seq_num);
	}
}
